<template>
  <q-page class="cc-admin">

    <div class="col bg-white shadow-2 q-pa-md q-ma-sm">
      <q-table flat color="primary" class="cross_table" :class="mobile ? 'flow-table-btn' : ''" separator="cell" :columns="columns" :data="list" row-key="id" :pagination.sync="pagination" :visible-columns="group" @request="query" :rows-per-page-options="[10, 20, 50, 100]" :selection="mobile ? 'none' : 'multiple'"
        :selected.sync="selected" :hide-bottom="false">

        <template v-slot:top="">
          <div class="row no-wrap full-width">

            <q-input clearable outlined dense placeholder="请输入关键字搜索" class="on-left" @input="query" debounce="500" v-model="key">
              <template #append>
                <q-btn flat round icon="search" color="primary" @click="query" :loading="loading">
                  <q-tooltip>搜索</q-tooltip>
                </q-btn>
              </template>
            </q-input>
            <q-space />
            <div class="q-gutter-xs">
              <q-btn icon="add" no-wrap color="primary" label="新建" @click="add" />

            </div>
          </div>
        </template>

        <template #body-cell-index="props">
          <q-td :props="props">{{ props.value }}</q-td>
        </template>
        <template #body-cell-suitability="props">
          <q-td key="suitability" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="suitabilityOptions" v-model="props.row.suitability" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-sufficiency="props">
          <q-td key="sufficiency" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="sufficiencyOptions" v-model="props.row.sufficiency" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-personnelPlace="props">
          <q-td key="personnelPlace" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="personnel_placeOptions" v-model="props.row.personnelPlace" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-personnelResponsibilities="props">
          <q-td key="personnelResponsibilities" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="personnel_responsibilitiesOptions" v-model="props.row.personnelResponsibilities" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-suppliesPlace="props">
          <q-td key="suppliesPlace" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="supplies_placeOptions" v-model="props.row.suppliesPlace" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-personalProtection="props">
          <q-td key="personalProtection" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="personal_protectionOptions" v-model="props.row.personalProtection" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-overallOrganization="props">
          <q-td key="overallOrganization" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="overall_organizationOptions" v-model="props.row.overallOrganization" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-divisionLaborRescueGroup="props">
          <q-td key="divisionLaborRescueGroup" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="division_labor_rescue_groupOptions" v-model="props.row.divisionLaborRescueGroup" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-evaluationActualCombatEffects="props">
          <q-td key="evaluationActualCombatEffects" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="evaluation_actual_combat_effectsOptions" v-model="props.row.evaluationActualCombatEffects" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-reportSuperiors="props">
          <q-td key="reportSuperiors" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="report_superiorsOptions" v-model="props.row.reportSuperiors" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-trafficPoliceDepartment="props">
          <q-td key="trafficPoliceDepartment" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="traffic_police_departmentOptions" v-model="props.row.trafficPoliceDepartment" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-medicalRescueDepartment="props">
          <q-td key="medicalRescueDepartment" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="medical_rescue_departmentOptions" v-model="props.row.medicalRescueDepartment" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #body-cell-surroundingGovernmentsEvacuated="props">
          <q-td key="surroundingGovernmentsEvacuated" :props="props">
            <div :class='calcRowColor(props.row)'><q-option-group debounce="500" hide-bottom-space :options="surrounding_governments_evacuatedOptions" v-model="props.row.surroundingGovernmentsEvacuated" type="radio" lazy-rules color="primary" inline disable /></div>
          </q-td>
        </template>
        <template #header-cell-opt="props">
          <q-th :props="props" :auto-width="true">
            {{ props.col.label }}
          </q-th>
        </template>
        <!-- <template #body-cell-opt="props">
                <q-td :props="props" :auto-width="true">
                    <q-btn :label="mobile?'查看':null" :outline="mobile" :rounded="mobile" :flat="!mobile" :round="!mobile" dense color="info" :icon="mobile?undefined:'mdi-text-box-search-outline'" v-show="formId!==parentFormId || props.row.status!=='未处理'" @click="viewForm(props.row)">
                        <q-tooltip>查看</q-tooltip>
                    </q-btn>

                    <q-btn v-auth="'fa21e28d53ebc024ec6bb0e09028ebb6:edit'" :label="mobile?'编辑':null" :outline="mobile" :rounded="mobile" :flat="!mobile" :round="!mobile" dense color="primary" :icon="mobile?undefined:'edit'" v-show="props.row.status==='未处理'" @click="edit(props.row)">
                        <q-tooltip>编辑</q-tooltip>
                    </q-btn>
                    <btn-del v-show="props.row.status==='未处理' || props.row.status==='作废'" :mobile="mobile" label="测试" @confirm="del(props.row)" v-auth="'fa21e28d53ebc024ec6bb0e09028ebb6:delete'" />
                </q-td>
            </template> -->
        <template #body-cell-opt="props">
          <q-td :props="props" :auto-width="true">
            <q-btn flat round dense color="primary" icon="edit" @click="edit(props.row)"> <q-tooltip>编辑</q-tooltip></q-btn>
            <!-- <q-btn
                                flat
                                round
                                dense
                                color="primary"
                                icon="mdi-content-copy"
                                @click="copy(props.row)"
                        >
                            <q-tooltip>复制</q-tooltip>
                        </q-btn> -->
            <btn-del label="应急训练和演习评估" @confirm="del(props.row)" />
          </q-td>
        </template>

      </q-table>
    </div>
    <q-dialog maximized flat persistent ref="dialog">
      <q-form @submit="submit" class="dialog_card column">
        <h5 class="view_title justify-between q-px-md">
          {{ editType }}
          <q-btn dense outline round icon="clear" size="sm" v-close-popup />
        </h5>
        <q-scroll-area class="col">
          <div class="row q-col-gutter-x-md dialog_form q-pa-md">
            <div class=" col-6">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label">
                  <q-icon name="star" color="red" v-show="true" />
                  预案名称
                </div>
                <!-- <select-search :formData="form" formKey="shipId" dense debounce="500" hide-bottom-space outlined v-model="form.shipId" :options="ship_idOptions" type="select" @blur="ship_idBlur105" @input="ship_idInput105(form
                                            .shipId,form)" lazy-rules :rules="[]" clearable emit-value map-options /> -->
                <q-input outlined dense v-model="form.namePlan" type="text" :rules="[requireTest]" />
              </div>
            </div>
            <div class=" col-6">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label">
                  <q-icon name="star" color="red" v-show="true" />
                  演练地点
                </div>
                <!-- <select-search :formData="form" formKey="shipId" dense debounce="500" hide-bottom-space outlined v-model="form.shipId" :options="ship_idOptions" type="select" @blur="ship_idBlur105" @input="ship_idInput105(form
                                            .shipId,form)" lazy-rules :rules="[]" clearable emit-value map-options /> -->
                <q-input outlined dense v-model="form.drillLocation" type="text" :rules="[requireTest]" />
              </div>
            </div>
            <div class="col-6" v-if="showForm[106]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="true" />
                  演练时间
                </div>
                <input-date-picker dense debounce="500" hide-bottom-space outlined v-model="form.drillTime" type="date" :form="form" beginDate="" endDate="" @blur="drill_timeBlur106" @input="drill_timeInput106(form
                  .drillTime, form)" lazy-rules :rules="[requireTest]" :readonly="!editableForm[106]" />
              </div>
            </div>

            <div class=" col-6">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label">
                  <q-icon name="star" color="red" v-show="false" />
                  演练类别
                </div>
                <select-search :formData="form" formKey="walkthroughCategory" dense debounce="500" hide-bottom-space outlined v-model="form.walkthroughCategory" :options="walkthrough_categoryOptions" type="select" @blur="walkthrough_categoryBlur108" @input="walkthrough_categoryInput108(form
                  .walkthroughCategory, form)" lazy-rules :rules="[]" clearable emit-value map-options />
              </div>
            </div>
            <div class="col-6">
              <h5> 组织部门</h5>
              <q-input outlined dense v-model="form.organizationDept" type="text" />
            </div>
            <div class="col-6">
              <h5> 总指挥</h5>
              <q-input outlined dense v-model="form.commander" type="text" />
            </div>

            <div class="col-12">
              <h5> 参加部门和单位</h5>
              <q-input outlined dense v-model="form.participatingDepartmentsUnits" type="text" />
            </div>

            <div class="col-12">
              <h5> 物资准备和人员培训情况</h5>
              <q-input outlined dense v-model="form.materialPreparationPersonnelTraining" type="textarea" rows="3" />
            </div>
            <div class="col-12">
              <h5> 演练过程描述</h5>
              <q-input outlined dense v-model="form.descriptionWalkthroughProcess" type="textarea" rows="3" />
            </div>

            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  预案适宜性充分性评审
                </div>

              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[111]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  适宜性
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="suitabilityOptions" v-model="form.suitability" type="radio" color="primary" inline :disable="!editableForm[111]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[115]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  充分性
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="sufficiencyOptions" v-model="form.sufficiency" type="radio" @blur="sufficiencyBlur115" @input="sufficiencyInput115(form
                  .sufficiency, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[115]" />
              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  演练效果及评估
                </div>
                <q-separator debounce="500" hide-bottom-space type="separator" lazy-rules :rules="[]" size="0.5px" color="dark" />

              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  人员到位情况
                </div>

              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[117]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  人员到位情况
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="personnel_placeOptions" v-model="form.personnelPlace" type="radio" @blur="personnel_placeBlur117" @input="personnel_placeInput117(form
                  .personnelPlace, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[117]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[118]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  人员职责
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="personnel_responsibilitiesOptions" v-model="form.personnelResponsibilities" type="radio" @blur="personnel_responsibilitiesBlur118" @input="personnel_responsibilitiesInput118(form
                  .personnelResponsibilities, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[118]" />
              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  物资到位情况
                </div>

              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[119]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  现场物资
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="supplies_placeOptions" v-model="form.suppliesPlace" type="radio" @blur="supplies_placeBlur119" @input="supplies_placeInput119(form
                  .suppliesPlace, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[119]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[120]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  个人防护
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="personal_protectionOptions" v-model="form.personalProtection" type="radio" @blur="personal_protectionBlur120" @input="personal_protectionInput120(form
                  .personalProtection, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[120]" />
              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  协调组织情况
                </div>

              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[121]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  整体组织
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="overall_organizationOptions" v-model="form.overallOrganization" type="radio" @blur="overall_organizationBlur121" @input="overall_organizationInput121(form
                  .overallOrganization, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[121]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[122]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  抢险组分工
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="division_labor_rescue_groupOptions" v-model="form.divisionLaborRescueGroup" type="radio" @blur="division_labor_rescue_groupBlur122" @input="division_labor_rescue_groupInput122(form
                  .divisionLaborRescueGroup, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[122]" />
              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  实战效果评价
                </div>

              </div>
            </div>
            <div class="display-item col-12" v-if="showForm[123]">
              <div class="dynamic-form-item">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />

                </div>
                <q-option-group debounce="500" hide-bottom-space :options="evaluation_actual_combat_effectsOptions" v-model="form.evaluationActualCombatEffects" type="radio" @blur="evaluation_actual_combat_effectsBlur123" @input="evaluation_actual_combat_effectsInput123(form
                  .evaluationActualCombatEffects, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[123]" />
              </div>
            </div>
            <div class="display-item col-12">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="font-size:14px;font-weight:800;">
                  <q-icon name="star" color="red" v-show="false" />
                  外部支援部门和协作有效性
                </div>

              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[124]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  报告上级
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="report_superiorsOptions" v-model="form.reportSuperiors" type="radio" @blur="report_superiorsBlur124" @input="report_superiorsInput124(form
                  .reportSuperiors, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[124]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[125]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  交警部门
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="traffic_police_departmentOptions" v-model="form.trafficPoliceDepartment" type="radio" @blur="traffic_police_departmentBlur125" @input="traffic_police_departmentInput125(form
                  .trafficPoliceDepartment, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[125]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[126]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  医疗救援部门
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="medical_rescue_departmentOptions" v-model="form.medicalRescueDepartment" type="radio" @blur="medical_rescue_departmentBlur126" @input="medical_rescue_departmentInput126(form
                  .medicalRescueDepartment, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[126]" />
              </div>
            </div>
            <div class="display-item col-6" v-if="showForm[127]">
              <div class="dynamic-form-item ">
                <div v-show="true" class="dynamic-form-item-label" style="width:100%;">
                  <q-icon name="star" color="red" v-show="false" />
                  周边政府撤离配合
                </div>
                <q-option-group debounce="500" hide-bottom-space :options="surrounding_governments_evacuatedOptions" v-model="form.surroundingGovernmentsEvacuated" type="radio" @blur="surrounding_governments_evacuatedBlur127" @input="surrounding_governments_evacuatedInput127(form
                  .surroundingGovernmentsEvacuated, form)" lazy-rules :rules="[]" color="primary" inline :disable="!editableForm[127]" />
              </div>
            </div>
            <div class="col-12" style="">
              <h5> 存在不足和改进措施</h5>
              <q-input outlined dense v-model="form.deficienciesImprovementMeasures" type="textarea" rows="3" />
            </div>
          </div>
        </q-scroll-area>
        <div class="row justify-center q-pa-md">
          <q-btn outline color="primary" icon="mdi-close-thick" label="关闭" v-close-popup />
          <q-btn class="q-mx-md" color="primary" icon="mdi-check-bold" label="提交" :loading="loading" type="submit" />
        </div>
      </q-form>
    </q-dialog>
    <confirm ref="confirmDialog" :msg="confirmMsg" @confirm="deleteBatch()" />
    <q-inner-loading :showing="loading">
      <q-spinner-gears size="50px" color="primary" />
    </q-inner-loading>
  </q-page>
</template>

<script>
import { IndexMixin } from 'boot/mixins';
import { getDictLabel } from 'boot/dictionary';
import confirm from 'components/confirm';

export default {
  name: 'EmergencyTrainingExerciseEvaluationForm',
  mixins: [IndexMixin],
  components: {
    confirm,
  },
  data() {
    return {
      organization_deptOptions: [],
      organization_deptOptionData: [],
      walkthrough_categoryOptions: [{
        label: '桌面演练',
        value: '1'
      }, {
        label: '实操演练',
        value: '2'
      }, {
        label: '船岸演习',
        value: '3',
        children: []
      }],
      walkthrough_categoryOptionData: [],
      suitabilityOptions: [{
        label: '全部能够执行',
        value: '1'
      }, {
        label: '执行过程不够顺利',
        value: '2'
      }, {
        label: '明显不适宜',
        value: '3',
        children: []
      }],
      suitabilityOptionData: [],
      sufficiencyOptions: [{
        label: '完全满足应急要求',
        value: '1'
      }, {
        label: '基本满足需要完善',
        value: '2'
      }, {
        label: '不充分，必须修改',
        value: '3',
        children: []
      }],
      sufficiencyOptionData: [],
      personnel_placeOptions: [{
        label: '迅速准确',
        value: '1'
      }, {
        label: '基本按时到位',
        value: '2'
      }, {
        label: '个别人员不到位',
        value: '3',
        children: []
      }, {
        label: '重点部位人员不到位',
        value: '4',
        children: []
      }],
      personnel_placeOptionData: [],
      personnel_responsibilitiesOptions: [{
        label: '职责明确，操作熟练',
        value: '1'
      }, {
        label: '职责明确，操作不够熟练',
        value: '2'
      }, {
        label: '职责不明，操作不熟练',
        value: '3',
        children: []
      }],
      personnel_responsibilitiesOptionData: [],
      supplies_placeOptions: [{
        label: '现场物资充分，全部有效',
        value: '1'
      }, {
        label: '现场准备不充分',
        value: '2'
      }, {
        label: '现场物资严重缺乏',
        value: '3',
        children: []
      }],
      supplies_placeOptionData: [],
      personal_protectionOptions: [{
        label: '全部人员防护到位',
        value: '1'
      }, {
        label: '个别人员防护不到位',
        value: '2'
      }, {
        label: '大部分人员防护 不到位',
        value: '3',
        children: []
      }],
      personal_protectionOptionData: [],
      overall_organizationOptions: [{
        label: '准确、高效',
        value: '1'
      }, {
        label: '协调基本顺利，能满足要求',
        value: '2'
      }, {
        label: '效率低，有待 改进',
        value: '3',
        children: []
      }],
      overall_organizationOptionData: [],
      division_labor_rescue_groupOptions: [{
        label: '合理、高效',
        value: '1'
      }, {
        label: '基本合理，能完成任务',
        value: '2'
      }, {
        label: '效率低，没有 完成任务',
        value: '值',
        children: []
      }],
      division_labor_rescue_groupOptionData: [],
      evaluation_actual_combat_effectsOptions: [{
        label: '达到预期目标',
        value: '1'
      }, {
        label: '基本达到目的，部分环节有待改进',
        value: '2'
      }, {
        label: '没有达到目标，须 重新演练',
        value: '3',
        children: []
      }],
      evaluation_actual_combat_effectsOptionData: [],
      report_superiorsOptions: [{
        label: '报告及时',
        value: '1'
      }, {
        label: '联系不上',
        value: '2'
      }],
      report_superiorsOptionData: [],
      traffic_police_departmentOptions: [{
        label: '按要求协作',
        value: '1'
      }, {
        label: '行动迟缓',
        value: '2'
      }, {
        label: '未涉及',
        value: '3',
        children: []
      }],
      traffic_police_departmentOptionData: [],
      medical_rescue_departmentOptions: [{
        label: '按要求协作',
        value: '1'
      }, {
        label: '行动迟缓',
        value: '2'
      }, {
        label: '未涉及',
        value: '3',
        children: []
      }],
      medical_rescue_departmentOptionData: [],
      surrounding_governments_evacuatedOptions: [{
        label: '按要求协作',
        value: '1'
      }, {
        label: '行动迟缓',
        value: '2'
      }, {
        label: '未涉及',
        value: '3',
        children: []
      }],
      surrounding_governments_evacuatedOptionData: [],
      form: {
        id: null,
        name_plan: null,
        drill_location: null,
        organization_dept: '',
        organization_dept_text: null,
        commander: null,
        drillTime: null,
        participating_departments_units: null,
        walkthroughCategory: null,
        material_preparation_personnel_training: null,
        description_walkthrough_process: null,
        suitability: null,
        sufficiency: null,
        personnelPlace: null,
        personnelResponsibilities: null,
        suppliesPlace: null,
        personalProtection: null,
        overallOrganization: null,
        divisionLaborRescueGroup: null,
        evaluationActualCombatEffects: null,
        reportSuperiors: null,
        trafficPoliceDepartment: null,
        medicalRescueDepartment: null,
        surroundingGovernmentsEvacuated: null,
        deficiencies_improvement_measures: null,
        walkthroughCategoryText: null
      },
      formId: '4b1ab97a14d4c6125a150e853525d5b5',
      autoLoadData: 'Y',
      title: '',
      parentFormId: '4b1ab97a14d4c6125a150e853525d5b5',
      reportCnd: null,
      flowShowViewForm: undefined,
      emptyForm: {
        id: null,
        name_plan: null,
        drill_location: null,
        organization_dept: '',
        organization_dept_text: null,
        commander: null,
        drillTime: null,
        participating_departments_units: null,
        walkthroughCategory: null,
        material_preparation_personnel_training: null,
        description_walkthrough_process: null,
        suitability: null,
        sufficiency: null,
        personnelPlace: null,
        personnelResponsibilities: null,
        suppliesPlace: null,
        personalProtection: null,
        overallOrganization: null,
        divisionLaborRescueGroup: null,
        evaluationActualCombatEffects: null,
        reportSuperiors: null,
        trafficPoliceDepartment: null,
        medicalRescueDepartment: null,
        surroundingGovernmentsEvacuated: null,
        deficiencies_improvement_measures: null,
        walkthroughCategoryText: null
      },
      searchForm: {
        search_2: ''
      },
      showForm: {
        101: true,
        102: true,
        104: true,
        105: true,
        106: true,
        108: true,
        109: true,
        111: true,
        112: true,
        114: true,
        115: true,
        116: true,
        117: true,
        118: true,
        119: true,
        120: true,
        121: true,
        122: true,
        123: true,
        124: true,
        125: true,
        126: true,
        127: true,
        130: true,
        131: true
      },
      editableForm: {
        101: true,
        102: true,
        104: true,
        105: true,
        106: true,
        108: true,
        109: true,
        111: true,
        112: true,
        114: true,
        115: true,
        116: true,
        117: true,
        118: true,
        119: true,
        120: true,
        121: true,
        122: true,
        123: true,
        124: true,
        125: true,
        126: true,
        127: true,
        130: true,
        131: true
      },
      resetShowForm: {
        101: true,
        102: true,
        104: true,
        105: true,
        106: true,
        108: true,
        109: true,
        111: true,
        112: true,
        114: true,
        115: true,
        116: true,
        117: true,
        118: true,
        119: true,
        120: true,
        121: true,
        122: true,
        123: true,
        124: true,
        125: true,
        126: true,
        127: true,
        130: true,
        131: true
      },
      columns: [
        {
          name: 'index',
          align: 'center',
          label: '序号',
          field: 'index',
        },
        {
          name: 'namePlan', align: 'center', label: '预案名称', field: 'namePlan',
        },
        {
          name: 'drillLocation', align: 'center', label: '演练地点', field: 'drillLocation',
        },
        /*         {
          name: 'organizationDept', align: 'left', label: '组织部门', field: 'organizationDept',
        },
        {
          name: 'commander', align: 'left', label: '总指挥', field: 'commander',
        }, */
        {
          name: 'drillTime', align: 'center', label: '演练时间', field: 'drillTime',
        },
        /*         {
          name: 'participatingDepartmentsUnits', align: 'left', label: '参加部门和单位', field: 'participatingDepartmentsUnits',
        },
        {
          name: 'walkthroughCategory', align: 'left', label: '演练类别', field: 'walkthroughCategoryText',
        },
        {
          name: 'materialPreparationPersonnelTraining', align: 'left', label: '物资准备和人员培训情况', field: 'materialPreparationPersonnelTraining',
        },
        {
          name: 'descriptionWalkthroughProcess', align: 'left', label: '演练过程描述', field: 'descriptionWalkthroughProcess',
        }, */
        /* {
          name: 'suitability', align: 'left', label: '适宜性', field: 'suitability',
        },
        {
          name: 'sufficiency', align: 'left', label: '充分性', field: 'sufficiency',
        },
        {
          name: 'personnelPlace', align: 'left', label: '人员到 位情况', field: 'personnelPlace',
        },
        {
          name: 'personnelResponsibilities', align: 'left', label: '人员职责', field: 'personnelResponsibilities',
        },
        {
          name: 'suppliesPlace', align: 'left', label: '现场物资', field: 'suppliesPlace',
        },
        {
          name: 'personalProtection', align: 'left', label: '个人防护', field: 'personalProtection',
        },
        {
          name: 'overallOrganization', align: 'left', label: '整体组织', field: 'overallOrganization',
        },
        {
          name: 'divisionLaborRescueGroup', align: 'left', label: '抢险组分工', field: 'divisionLaborRescueGroup',
        },
        {
          name: 'evaluationActualCombatEffects', align: 'left', label: '实战效果评价', field: 'evaluationActualCombatEffects',
        },
        {
          name: 'reportSuperiors', align: 'left', label: '报告上级', field: 'reportSuperiors',
        },
        {
          name: 'trafficPoliceDepartment', align: 'left', label: '交警部门', field: 'trafficPoliceDepartment',
        },
        {
          name: 'medicalRescueDepartment', align: 'left', label: '医疗救援部门', field: 'medicalRescueDepartment',
        },
        {
          name: 'surroundingGovernmentsEvacuated', align: 'left', label: '周边政府撤离配合', field: 'surroundingGovernmentsEvacuated',
        },
        {
          name: 'deficienciesImprovementMeasures', align: 'left', label: '存在不足和改进措施', field: 'deficienciesImprovementMeasures',
        }, */
        {
          name: 'opt', align: 'center', label: '操作', field: 'id',
        },
      ],
      showQuery: true,
      headers: [{ name: 'Authorization', value: localStorage.Authorization }],
      uploadUrl: `${process.env.SERVER_URL}${process.env.BASE_URL}/sys/common/upload`,
      imgUrl: `${process.env.SERVER_URL}${process.env.BASE_URL}/sys/common/static`,
      url: {
        list: '/evluate/trainingExerciseEvaluationForm/list',
        add: '/evluate/trainingExerciseEvaluationForm/add',
        edit: '/evluate/trainingExerciseEvaluationForm/edit',
        copy:
          '/evluate/trainingExerciseEvaluationForm/copy',
        delete: '/evluate/trainingExerciseEvaluationForm/delete',
        deleteBatch: '/evluate/trainingExerciseEvaluationForm/deleteBatch',
        exportXlsUrl: '/evluate/trainingExerciseEvaluationForm/exportXls',
        importExcelUrl: '/evluate/trainingExerciseEvaluationForm/importExcel',
      },
    };
  },
  methods: {
    requireTest(val) {
      return val === 0 || (val && ((`${val}`).length > 0)) || '这是必填字段';
    },
    name_planBlur101(evt, editAfter) {

    },
    drill_locationBlur102(evt, editAfter) {

    },
    organization_deptBlur104(evt, editAfter) {

    },
    commanderBlur105(evt, editAfter) {

    },
    drill_timeBlur106(evt, editAfter) {

    },
    participating_departments_unitsBlur131(evt, editAfter) {

    },
    walkthrough_categoryBlur108(evt, editAfter) {

    },
    material_preparation_personnel_trainingBlur109(evt, editAfter) {

    },
    description_walkthrough_processBlur112(evt, editAfter) {

    },
    field114Blur114(evt, editAfter) {

    },
    suitabilityBlur111(evt, editAfter) {

    },
    sufficiencyBlur115(evt, editAfter) {

    },
    field116Blur116(evt, editAfter) {

    },
    personnel_placeBlur117(evt, editAfter) {

    },
    personnel_responsibilitiesBlur118(evt, editAfter) {

    },
    supplies_placeBlur119(evt, editAfter) {

    },
    personal_protectionBlur120(evt, editAfter) {

    },
    overall_organizationBlur121(evt, editAfter) {

    },
    division_labor_rescue_groupBlur122(evt, editAfter) {

    },
    evaluation_actual_combat_effectsBlur123(evt, editAfter) {

    },
    report_superiorsBlur124(evt, editAfter) {

    },
    traffic_police_departmentBlur125(evt, editAfter) {

    },
    medical_rescue_departmentBlur126(evt, editAfter) {

    },
    surrounding_governments_evacuatedBlur127(evt, editAfter) {

    },
    deficiencies_improvement_measuresBlur130(evt, editAfter) {

    },
    name_planInput101(v, row, editAfter) {

    },
    drill_locationInput102(v, row, editAfter) {

    },
    organization_deptInput104(v, row, editAfter) {
      // 这里给名称字段赋值
      if (v instanceof Array) {
        const nameArray = [];
        if (this.form) {
          this.form.organization_dept_text = '';
          v.forEach((id) => {
            const opt = this.organization_deptOptions.find((o) => o.value === id);
            if (opt) {
              nameArray.push(opt.label);
            }
            this.form.organization_dept_text = nameArray.join(',');
          });
        }
      } else {
        const opt = this.organization_deptOptions.find((o) => o.value === v);
        if (opt) {
          this.form.organization_dept_text = opt.label;
        }
        if (!v) {
          this.form.organization_dept_text = '';
        }
      }
    },
    commanderInput105(v, row, editAfter) {

    },
    drill_timeInput106(v, row, editAfter) {

    },
    participating_departments_unitsInput131(v, row, editAfter) {

    },
    walkthrough_categoryInput108(v, row, editAfter) {
      // 这里给名称字段赋值
      if (v instanceof Array) {
        const nameArray = [];
        if (this.form) {
          this.form.walkthroughCategoryText = '';
          v.forEach((id) => {
            const opt = this.walkthrough_categoryOptions.find((o) => o.value === id);
            if (opt) {
              nameArray.push(opt.label);
            }
            this.form.walkthroughCategoryText = nameArray.join(',');
          });
        }
      } else {
        const opt = this.walkthrough_categoryOptions.find((o) => o.value === v);
        if (opt) {
          this.form.walkthroughCategoryText = opt.label;
        }
        if (!v) {
          this.form.walkthroughCategoryText = '';
        }
      }
    },
    material_preparation_personnel_trainingInput109(v, row, editAfter) {

    },
    description_walkthrough_processInput112(v, row, editAfter) {

    },
    field114Input114(v, row, editAfter) {

    },
    suitabilityInput111(v, row, editAfter) {

    },
    sufficiencyInput115(v, row, editAfter) {

    },
    field116Input116(v, row, editAfter) {

    },
    personnel_placeInput117(v, row, editAfter) {

    },
    personnel_responsibilitiesInput118(v, row, editAfter) {

    },
    supplies_placeInput119(v, row, editAfter) {

    },
    personal_protectionInput120(v, row, editAfter) {

    },
    overall_organizationInput121(v, row, editAfter) {

    },
    division_labor_rescue_groupInput122(v, row, editAfter) {

    },
    evaluation_actual_combat_effectsInput123(v, row, editAfter) {

    },
    report_superiorsInput124(v, row, editAfter) {

    },
    traffic_police_departmentInput125(v, row, editAfter) {

    },
    medical_rescue_departmentInput126(v, row, editAfter) {

    },
    surrounding_governments_evacuatedInput127(v, row, editAfter) {

    },
    deficiencies_improvement_measuresInput130(v, row, editAfter) {

    },

    // 逻辑表单设置
    logicInputSet(editAfter) {

    },
    getDictLabel,
    initDict() {

    },
    afterQuery() {

    },
    addBefore() {
      this.form = {
        dynFormId: this.formId,
        parentFormId: this.parentFormId,
        parentId: this.parentId,
        catalog_id: this.catalog,
        ...this.emptyForm
      };

      if (this.form.organization_dept) {
        this.organization_deptInput104(this.form.organization_dept);
      }

      return true;
    },
    saveBefore() {
      return true;
    },
    calcListForAdd() {

    },
    setSubFormListForEdit(result) {

    },
    editAfter() {
      // 只有编辑触发 为 true才进行触发
      if (this.form.organization_dept) {
        this.organization_deptInput104(this.form.organization_dept, {}, true);
      }
    },
    saveSubFormList() {

    },
    calcRowColor(row) {
      return '';
    },
  },
  mounted() {
    this.initDict();
  },
  computed: {

  }
};
</script>

<style lang="stylus">

</style>
